package com.cy.springcloudalibaba.feign;

import com.cy.springcloudalibaba.models.Product;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestParam;

/**
 * @Description: 商品
 * @ClassName: FeignProductService
 * @Author: chenyu
 * @Date: 2025/2/6 13:54
 */
@FeignClient(name = "08-seata-distributed-product-service")
public interface FeignProductService {
    @PostMapping("/product/reduceStock")
    Product reduceStock(@RequestParam("productId") Integer productId, @RequestParam("amount") Integer amount);
}
